<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:a4j="http://richfaces.org/a4j"
	xmlns:rich="http://richfaces.org/rich"
	xmlns:t="http://myfaces.apache.org/tomahawk">

<ui:composition template="layout/layout.xhtml">
	<ui:define name="content">
		<f:view locale="#{LocalizationController.locale}">
			<h:form styleClass="form-horizontal">
				<div class="span6">
					<h3><h:outputText value="#{msgs.Session1Creation}" /></h3>
					<div class="control-group" style="margin-top:40px;">
						<label for="menu_test_plan" class="control-label">Test Plan</label>
						<div class="controls">
							<h:selectOneMenu id="menu_test_plan" value="#{SessionManagerController.selectedTestPlan}">
								<f:selectItems value="#{SessionManagerController.testPlanSelection}" var="testPlan"
        							itemValue="#{testPlan.id}" itemLabel="#{testPlan.name}"/>
							</h:selectOneMenu>
						</div>
					</div>
					<div class="control-group">
						<label for="menu_sut" class="control-label">SUT</label>
						<div class="controls">
							<h:selectOneMenu id="menu_sut" value="#{SessionManagerController.selectedSUT}" >
								<f:selectItems value="#{SessionManagerController.SUTSelection}" var="sut"
        							itemValue="#{sut.id}" itemLabel="#{sut.name}"/>
							</h:selectOneMenu>
						</div>
					</div>
  					
  					
  					<div class="control-group">
						
						<div class="controls">
							<h:commandLink styleClass="btn btn-primary" value="#{msgs.Common1Create}" action="#{SessionManagerController.createNewSession}" />
      						<h:commandLink styleClass="btn" value="#{msgs.Common2Cancel}" action="#{SessionManagerController.cancel}" style="margin-left: 10px;"/>
						</div>
					</div>
					
					<div class="control-group">
						
						<div class="controls" style="width: 230px;">
							<a4j:outputPanel styleClass="formErrorMessage" ajaxRendered="true" rendered="#{SessionManagerController.showSessionFormMessage}">
	      						<div class="alert alert-error">
									<h:outputText value="#{SessionManagerController.sessionFormMessage}" rendered="#{SessionManagerController.showSessionFormMessage}" />
								</div>
							</a4j:outputPanel>	
						</div>
					</div>
  					
  					
  				</div>
  				<div class="span5"> </div>
			</h:form>
		</f:view>
	</ui:define>
</ui:composition>
</html>